<?

JCAT_Package::ImportClass('JCAT_Controller',JCAT::PACKAGE_MVC) ;

class UICtrlBaseInfo extends JCAT_Controller
{
	/**
	 * what's this
	 * 
	 * @access	public
	 * @param	$aParent	JCAT_ViewGtk		拥有此视图的对象
	 * @param	$aDoc		UICtrlDocBase		主文档
	 * @return	array
	 */
	public function UICtrlBaseInfo(JCAT_IController $aParent,UICtrlDocBase $aDoc)
	{
		$this->JCAT_Controller(__CLASS__, $aParent) ;

		// 文档
		$this->AddDocument($aDoc,'MainDoc') ;
		
		// 视图
		$aSubView = new UICtrlBaseInfoView($this) ;
		$aSubView->SetDocument($aDoc) ;
		$this->AddView($aSubView) ;		
	}


	/**
	 * 
	 *
	 * @access	public
	 * @return	void
	 */
	public function MainRun()
	{
		// 对话框 视图
		$aView = $this->GetView('UICtrlBaseInfoView') ;
		$aView->ShowView() ;
	}

	
	/**
	 * what's this
	 * 
	 * @access	public
	 * @param	$nTypes			int			what's this
	 * @param	$nSelected		int			what's this
	 * @return	void
	 */
	public function SetImplementType( $nTypes, $nSelected=0 )
	{
		// 
		$aUICtrlBaseInfoView = $this->GetView('UICtrlBaseInfoView') ;
		JCAT_ASSERT::ASSERT_INSTANCE($aUICtrlBaseInfoView,'UICtrlBaseInfoView') ;
		
		$aUICtrlBaseInfoView->SetImplementType($nTypes,$nSelected) ;
	}
}

?>